// 盒子基础设置
@mixin box($w:100%, $h:100%){
  width: $w;
  height: $h;
}
/**
 * 字体基础属性
 * fz : 字体大小
 * fw : 字体粗细
 */
@mixin font($fz, $cor:null, $fw:null, $fm:null){
  font-size: $fz;
  @if $cor {
    color: $cor;
  }
  @if $fw{
    font-weight: $fw;
  }
  @if $fm {
    font-family: $fm;
  }
}

/**
 * 边框
 */
@mixin border($borderWidth, $borderColor, $radio:0){
  border: $borderWidth solid;
  border-radius: $radio;
  @if $borderColor {
    border-color: $borderColor;
  }
}

/**
 * flex布局属性
 * dir   : 对齐方式
 * main  : 主轴
 * cross : 交叉轴
 */
@mixin flex($dir:row, $main:flex-start, $cross:stretch) {
  display: flex;
  flex-direction: $dir;
  justify-content: $main;
  align-items: $cross;
}

/**

 */
@mixin color-logo ($colorA, $colorB) {
  color: transparent;
  font-family: current, sans-serif;
  margin-top: 14px;
  letter-spacing: 1px;
  background: linear-gradient(
      90deg,
      $colorA,
      $colorB,
      $colorA
  );
  -webkit-background-clip: text;
  animation: glow 10s linear infinite;
  transition: 1.5s;
  background-size: 300%;

  @keyframes glow {
    to {
      background-position: -300%;
    }
  }
}

